-- @owner: songjing20
-- @date: 2024-7-12
-- @testpoint: explain select 搭配各种参数使用,合理报错

--step1:建表;expect:成功
create table t_explain_0073_1 (
    d_w_id integer not null,
    d_id integer not null,
    d_ytd decimal(12, 2),
    d_tax decimal(4, 4),
    d_next_o_id integer,
    d_name varchar(10),
    d_street_1 varchar(20),
    d_street_2 varchar(20),
    d_city varchar(20),
    d_state char(2),
    d_zip char(9)
);
create table t_explain_0073_2 (
    hist_id integer,
    h_c_id integer,
    h_c_d_id integer,
    h_c_w_id integer,
    h_d_id integer,
    h_w_id integer,
    h_date timestamp,
    h_amount decimal(6, 2),
    h_data varchar(24)
);
create table t_explain_0073_3 (
    no_w_id integer not null,
    no_d_id integer not null,
    no_o_id integer not null
);
create table t_explain_0073_4 (
    o_w_id integer not null,
    o_d_id integer not null,
    o_id integer not null,
    o_c_id integer,
    o_carrier_id integer,
    o_ol_cnt integer,
    o_all_local integer,
    o_entry_d timestamp
);
create table t_explain_0073_5 (
    ol_w_id integer not null,
    ol_d_id integer not null,
    ol_o_id integer not null,
    ol_number integer not null,
    ol_i_id integer not null,
    ol_delivery_d timestamp,
    ol_amount decimal(6, 2),
    ol_supply_w_id integer,
    ol_quantity integer,
    ol_dist_info char(24)
);
create table t_explain_0073_6 (
    s_w_id integer not null,
    s_i_id integer not null,
    s_quantity integer,
    s_ytd integer,
    s_order_cnt integer,
    s_remote_cnt integer,
    s_data varchar(50),
    s_dist_01 char(24),
    s_dist_02 char(24),
    s_dist_03 char(24),
    s_dist_04 char(24),
    s_dist_05 char(24),
    s_dist_06 char(24),
    s_dist_07 char(24),
    s_dist_08 char(24),
    s_dist_09 char(24),
    s_dist_10 char(24)
);

--step2:explain select 搭配各种参数使用;expect:成功
EXPLAIN ANALYZE
SELECT DISTINCT CAST(
        coalesce(
            stddev_pop(
                CAST(
                    CAST(
                        CAST(
                            nullif(
                                octet_length(
                                    CAST(
                                        CAST(
                                            '?}k2pDK/W/#NgiMZ~6X9azD[EI@~b~-nc85BC8foB6J1nm}C35O@gvAE8br$6-MR2UXu2C7Gm/EXJH3oZx?&7l7]lT~.7L*~EB5/ZS8L}MCz8TNWmTcE\\d1LSBw?X)uvb*ROnAW~_2oy.G1v+@*g+.[E{kB4S93WU1w+q_0nN3)LyOmu+CVb--+83Zny-NL?wYy}KBt{1E3M.QTj1B*{RgEA3HMJM}Du*B!4Hq4I6gDC1*UIN4962YMwK~xmSgPI' as TEXT
                                        ) as TEXT
                                    )
                                ),
                                CAST(
                                    CAST(
                                        CAST(83 AS INTEGER) # CAST(
                                        CAST(69 AS INTEGER) - CAST(
                                            CAST(CAST('((344,185),838)' as CIRCLE) AS CIRCLE) <->CAST(CAST('((456,653),64)' as CIRCLE) AS CIRCLE) AS INTEGER
                                        ) AS INTEGER
                                    ) AS INTEGER
                                ) # CAST(38 AS INTEGER) AS INTEGER
                            ) - CAST(
                                @@ CAST(CAST('((828,642),61)' as CIRCLE) as CIRCLE) AS INTEGER
                            )
                        ) as INTEGER
                    ) AS INTEGER
                ) << CAST(
                    CAST(
                        numnode(CAST('SbuV:*'::tsquery as TSQUERY)) AS INTEGER
                    ) * CAST(
                        character_length(
                            CAST(
                                CAST(
                                    'wAr9Fv1QCx3c3_DE083ORn8CYq3_y4OSfN_iH7sESb7+OK9B+yomG03l5C#9.%4}^k+}iFlN3I+Y1vL6os+yUt_y4twYDuA5BuH3ywPP89giMY$P}Lixc4Cxo2@xvDL?wDH*jH?AOC#tD6oeL#E_P)U~~J8BB3*5Q9biB#7Nf3z/c?+5dln2Cepkp5807LJoCEPu7As80WzaPA+x2nhrYN+Z3i*5qcW}In+fG5?\\UBHymL8WrAML#pZGFvONS+5H' as TEXT
                                ) as TEXT
                            )
                        ) AS INTEGER
                    ) AS INTEGER
                ) as INTEGER
            )
        ) OVER (
            PARTITION BY ref_2.xmin
            ORDER BY ref_1.o_all_local
        ),
        variance(
            CAST(
                @ CAST(
                    pg_stat_get_db_numbackends(
                        CAST(
                            pg_stat_get_db_numbackends(
                                CAST(
                                    @@ CAST(CAST('((177,82),410)' as CIRCLE) as CIRCLE) as INTEGER
                                )
                            ) as INTEGER
                        )
                    ) as INTEGER
                ) as INTEGER
            )
        ) OVER (
            PARTITION BY ref_1.o_all_local
            ORDER BY ref_0.cmin
        )
    ) as INTEGER
) as c0
from  t_explain_0073_6 as ref_0
    inner join  t_explain_0073_4 as ref_1 on (true)
    left join  t_explain_0073_1 as ref_2 on (false)
WHERE EXISTS (
        SELECT ref_2.d_next_o_id as c0,
            ref_5.xmax as c1
        from  t_explain_0073_2 as ref_5
        WHERE EXISTS (
                SELECT DISTINCT stddev_pop(
                        CAST(
                            @-@ CAST(
                                CAST(
                                    '((240,649),(535,313),(565,377),(543,682),(722,963),(958,428),(767,857),(719,680),(700,756),(125,821),(431,484),(127,780),(686,587),(47,336),(778,562),(972,211),(813,458),(251,566),(503,920),(132,105),(906,590),(603,23),(230,301),(922,583),(308,164),(308,537),(323,830),(935,564),(668,161),(599,660),(785,94),(819,490),(965,788),(211,423),(459,763),(539,703),(16,107),(41,254),(557,162),(25,799),(943,383),(144,460),(771,144),(85,928),(325,41),(834,672),(995,60),(698,994),(297,609),(797,795),(191,510),(867,356),(174,971),(496,418),(374,268),(557,560),(593,913),(576,735),(375,946),(312,181),(605,635),(206,37),(874,874),(745,52),(544,410),(111,735),(325,94),(694,774),(976,300),(57,503),(750,362),(615,24),(597,943),(893,620),(472,607),(444,129),(962,689),(202,773),(302,346),(304,239),(548,532),(910,958),(30,36),(970,666),(1004,949),(99,826),(964,880),(861,28),(379,3),(241,692),(56,382),(68,912),(704,953),(100,93),(656,368),(239,757),(309,840),(275,191),(694,980),(893,52),(999,246),(1021,816),(768,797),(264,484),(673,225),(29,154),(311,142),(690,891),(258,133),(675,542),(183,961),(518,909),(620,711),(239,80),(98,795),(918,840),(298,677),(442,445),(779,765),(35,864),(165,932),(173,24),(378,720),(533,570),(546,400),(255,170),(306,402),(261,689),(771,963),(22,948),(679,720),(20,976),(609,477),(259,314),(175,366),(774,430),(908,87),(682,890),(453,308),(404,237),(24,270),(755,772),(39,862),(195,856),(262,323),(125,273),(754,313),(426,440),(201,584),(637,834),(609,233),(898,605),(809,692),(629,431),(767,361),(186,654),(387,59),(644,205),(728,639),(185,706),(1007,113),(505,739),(661,816),(300,52),(722,442),(474,865),(221,492),(432,937),(413,366),(779,444),(793,986),(759,614),(605,414),(561,909),(270,367),(897,23),(87,490),(566,314),(635,519),(463,1000),(352,377),(811,982),(520,283),(223,634),(377,777),(131,663),(337,831),(537,993),(141,230),(821,426),(625,116),(709,498),(752,902),(353,225),(396,263),(773,44),(584,30),(577,452),(692,532),(504,66),(980,713),(982,538),(186,732),(732,935),(575,102),(474,508),(524,399),(674,424),(1025,362),(861,130),(93,580),(635,104),(79,788),(641,816),(249,435),(52,57),(668,15),(8,195),(723,624),(574,537),(598,894),(804,699),(701,657),(550,628),(44,788),(760,134),(915,1014),(73,964),(358,641),(169,91),(474,79),(470,942),(523,35),(266,484),(3,199),(707,324),(948,505),(668,321),(702,624),(156,300),(962,33),(700,265),(310,799),(703,1008),(989,863),(804,578),(48,162),(74,782),(909,577),(531,933),(443,176),(374,15),(455,485),(337,950),(507,551),(26,283))' as PATH
                                ) as PATH
                            ) as INTEGER
                        )
                    ) OVER (
                        PARTITION BY ref_7.ol_quantity
                        ORDER BY ref_0.s_w_id
                    ) as c0,
                    ref_5.h_c_id as c1,
                    ref_5.h_d_id as c2,
                    ref_0.s_w_id as c3,
                    ref_1.o_all_local as c4,
                    ref_5.xmin as c5,
                    hll_hash_integer(
                        CAST(
                            # CAST(
                            CAST(
                                '((339,42),(983,598),(767,831),(54,874),(976,758),(139,117),(24,543),(21,975),(1012,444),(662,1003),(17,664),(195,563),(628,83),(647,581),(994,992),(279,352),(178,747),(625,722),(403,499),(318,564),(891,716),(187,666),(922,45),(193,831),(293,532),(330,234),(74,957),(988,860),(724,857),(761,35),(229,961),(745,323),(711,188),(274,928),(556,636),(137,542),(515,862),(405,914),(896,111),(94,696),(42,253),(448,518),(196,686),(981,770),(306,559),(169,351),(645,206),(57,200),(95,497),(551,478),(150,797),(461,293),(435,549),(432,450),(57,637),(283,354),(778,948),(967,274),(966,898),(1025,298),(246,22),(233,375),(427,798),(786,563),(718,724),(575,653),(990,499),(129,604),(410,542),(375,170),(303,311),(990,752),(242,53),(725,572),(380,798),(650,189),(582,647),(163,933),(303,866),(1005,441),(707,842),(287,11),(191,127),(80,528),(895,37),(610,792),(508,21),(469,482),(916,390),(410,149),(873,522),(1019,49),(770,109),(767,27),(143,470),(826,152),(29,1004),(32,646),(513,57),(848,615),(600,331),(161,231),(269,766),(830,825),(1015,92),(928,601),(930,851),(402,376),(487,399),(635,300),(860,969),(97,277),(135,497),(707,651),(132,564),(32,340),(217,232),(334,843),(236,409),(516,409),(435,694),(47,156),(264,167),(663,275),(457,83),(655,511),(35,1024),(40,596),(552,842),(770,586),(812,410),(448,1019),(195,86),(796,250),(741,480),(674,602),(557,8),(460,959),(351,248),(985,567),(812,588),(981,505),(930,766),(188,902),(110,340),(471,191),(315,476),(138,849),(736,432),(105,457),(916,916),(176,487),(864,88),(615,894),(103,213),(771,156),(185,214),(757,70),(342,607),(725,42),(876,543),(388,630),(895,25),(242,242),(319,380),(428,833),(870,85),(865,525),(278,191),(662,319),(412,691),(561,144),(327,343),(92,604),(874,420),(555,724),(781,936),(844,33),(88,177),(511,787),(170,204),(827,856),(380,588),(302,175),(1008,955),(727,608),(30,542),(580,167),(367,241),(18,779),(873,3),(367,501),(113,427),(504,261),(190,917),(250,707),(1009,28),(8,1003),(57,904),(260,757),(901,583),(264,136),(6,769),(634,893),(729,932),(113,951),(685,549),(875,250),(341,1005),(51,18),(129,852),(90,199),(623,776),(553,361),(968,193),(992,308),(766,742),(546,458),(237,3),(965,147),(429,109),(422,575),(592,426),(673,273),(1015,352),(1009,593),(214,116),(467,448),(179,735),(951,870),(996,344),(142,861),(972,485),(351,243),(540,651),(214,155),(56,515),(989,824),(958,590),(851,181),(621,176),(573,898),(482,598),(706,234),(796,587),(988,762),(41,460),(403,652),(952,546),(20,779),(379,287),(873,407),(460,667),(710,771),(180,470),(947,484))' as PATH
                            ) as PATH
                        ) as INTEGER
                    )
            ) as c6,
            (
                SELECT cmax
                FROM  t_explain_0073_3
                LIMIT 1 OFFSET 3
            ) as c7,
            ref_1.o_d_id as c8,
            ref_0.cmin as c9,
            ref_0.ctid as c10,
            ref_1.o_carrier_id as c11,
            sum(
                CAST(
                    CAST(78 AS INTEGER) >> CAST(
                        # CAST(
                        CAST(
                            '((521,979),(549,539),(943,151),(716,110),(533,711),(485,177),(237,665),(626,270),(981,452),(259,356),(839,94),(854,751),(633,675),(672,5),(347,941),(826,792),(981,1002),(137,830),(493,29),(688,406),(69,607),(596,279),(598,761),(138,820),(477,247),(605,890),(190,689),(751,859),(549,884),(78,900),(937,471),(690,899),(57,39),(114,188),(585,959),(822,443),(255,197),(998,900),(200,46),(325,543),(183,271),(234,613),(394,809),(16,322),(204,125),(111,591),(757,362),(806,204),(33,3),(752,127),(993,214),(510,831),(413,314),(578,297),(699,950),(239,216),(1019,61),(848,534),(634,907),(932,317),(1019,708),(378,931),(271,129),(879,958),(210,932),(1009,610),(741,1014),(587,811),(992,826),(762,354),(549,193),(583,510),(257,546),(838,175),(148,733),(504,943),(366,25),(943,916),(909,789),(899,293),(111,62),(919,79),(918,44),(247,533),(378,503),(535,576),(24,675),(326,512),(368,3),(80,495),(857,56),(537,218),(829,75),(127,255),(552,120),(10,172),(317,126),(228,211),(300,775),(555,953),(720,747),(200,615),(130,339),(174,467),(47,387),(942,159),(735,830),(870,892),(671,820),(952,13),(472,64),(803,365),(945,287),(676,864),(520,636),(4,141),(271,308),(65,260),(179,195),(1012,68),(745,343),(86,360),(238,430),(263,573),(172,414),(426,95),(905,791),(931,777),(779,156),(131,645),(730,124),(622,73),(606,945),(353,462),(700,11),(476,574),(175,280),(187,967),(911,265),(628,370),(916,773),(128,555),(236,511),(534,466),(243,48),(200,425),(651,804),(199,902),(162,508),(525,835),(214,371),(787,56),(511,328),(72,438),(761,858),(331,476),(892,638),(448,830),(989,986),(124,127),(922,585),(293,248),(323,967),(338,578),(284,239),(106,550),(289,936),(912,39),(599,668),(569,59),(805,849),(597,7),(726,904),(511,866),(731,369),(42,671),(533,521),(279,148),(119,370),(907,187),(292,839),(687,804),(303,232),(61,239),(48,662),(650,602),(977,867),(547,176),(933,404),(394,390),(524,257),(449,266),(358,758),(44,21),(653,422),(108,619),(622,84),(359,969),(473,266),(151,414),(609,265),(61,976),(332,977),(702,545),(5,709),(645,510),(846,629),(861,347),(205,155),(728,420),(44,697),(993,190),(622,743),(624,273),(734,967),(155,693),(811,50),(715,528),(695,538),(896,60),(993,779),(452,132),(570,985),(627,32),(490,994),(346,971),(134,751),(604,600),(640,946),(449,313),(186,561),(628,997),(532,892),(840,205),(769,619),(108,492),(306,578),(486,112),(760,820),(744,850),(6,578),(825,393),(848,889),(127,609),(499,791),(601,21),(880,754),(552,762),(137,84),(940,60),(328,96),(252,625),(681,89),(622,725),(648,1021),(233,450))' as PATH
                        ) as PATH
                    ) AS INTEGER
                ) as INTEGER
            )
    ) OVER (
        PARTITION BY ref_2.d_zip
        ORDER BY ref_0.s_dist_01
    ) as c12,
    ref_0.s_w_id as c13,
    ref_1.o_all_local as c14
from  t_explain_0073_5 as ref_7,
    (
        SELECT ref_5.xc_node_id as c0
        from  t_explain_0073_3 as ref_8
        WHERE true
        LIMIT 168
    ) as subq_0
WHERE ref_5.tableoid is NULL
LIMIT 137
)
LIMIT 93
) CONNECT BY EXISTS (
    SELECT DISTINCT 33 as c0,
        stddev_pop(
            CAST(
                CAST(
                    bit_length(
                        CAST(
                            CAST(
                                'y{JKSFNIgV7zDZszrKQLR0k[ReY\\Ge\\6y/\\bKL&-[6R9rxDB#$Azjwz_8Csn7AY+mIE1rocB\\5CyX(r-c6f9HD@nqq?snS*F?*Ln@lP]mG6U%#EC@$?4At%*2o1KO2#zs_qyInCJqtf9@zB95n2dRz3iIU8}6gM1FW8GaXfZJY)3m$wcbg.BL$)V%fTC6ySou9LZL7$wY+fbkB{.Do]Z!AhfG^hysGV2$6Sq3ei$mySCOD0do[?*}fLZRUd@8kAD' as TEXT
                            ) as TEXT
                        )
                    ) AS INTEGER
                ) * CAST(
                    CAST(
                        lengthb(
                            CAST(
                                CAST(
                                    'o+.wC{}6BfnXrL0$ugZ8IB3fQjE8l%R+YpV+*x)ED62392Gq7Kg\\-8p\\YWH9y\\OBDLwS(5t#?K%ZPv!kE%w[njp5dfSE8GVxpCgDBER-UhCHEX56xsD$Lj_glC*$T_QLdJoVGH7Ng@EhV*c1{o6c4mDg8*%.I8AERB5gPGosj3DER7eRl8wij1I{$afI^#dq]+lEltCX2$4l5zMz6i)z!/A{301uoC($fEklC9!I6DCc^MB7$yccAWZedqxxUi65' as TEXT
                                ) as TEXT
                            )
                        ) AS INTEGER
                    ) / CAST(85 AS INTEGER) AS INTEGER
                ) as INTEGER
            )
        ) OVER (
            PARTITION BY ref_0.s_ytd
            ORDER BY ref_2.d_street_2
        ) as c1,
        pg_stat_get_db_tuples_deleted(
            CAST(
                bit_length(
                    CAST(
                        CAST(
                            '5~[M~P3zPkhf(Q*aATPB+xBQ4@{w)W-IN4CXA0A_53zMJBdl+cfc!?rrZVypD1g/y98BYBoj[[1EV1%CBn5S2c+M6J2x8bys\\Lcr7xilw2Q(1gkPAEAuJ{9CC8)#28.H6K9iI^{4osmiNL7D8+.GkqA1ZEGEb+\\2*Y$Bz^n-9^Ss19i+jOs-Bx1w&WC$?oVfJ._*!w1}JFBp&?8SbZdCW2y7\\k5LlS~qXD.%r1X3mZVA[U%6#4WAm%P.739\ _.M' as TEXT
                        ) as TEXT
                    )
                ) as INTEGER
            )
        ) as c2,
        ref_1.ctid as c3,
        pg_stat_get_blocks_fetched(
            CAST(
                stddev_samp(
                    CAST(
                        CAST(
                            lengthb(
                                CAST(
                                    CAST(
                                        'f4*Z.E2TESkCjA@5#By3P^c4]nAAg)GcUfU**.SeGt3\\8mK8oT{kLpOD8KxNy\\rS\\9zB8&X5Y5]DN4(VxfKjBDC8b23Zxyt-aeAbAv7i7DuT0483X4q5#@@VZQB.qoP@*C9g*q_e1l~I2ht7qA%Iz\\/[13nEBf&Pk{R.1E4.J8nu&e7HC*adYP]4T]w7**]honh{RK5rUfIL_p8j+5[2}g\\633E*82a9CS^7Cm~A1/]^%7pMP1651bo/i$P4ATIJ' as TEXT
                                    ) as TEXT
                                )
                            ) AS INTEGER
                        ) * CAST(
                            CAST(
                                @-@ CAST(
                                    CAST(
                                        '((312,181),(465,15),(680,223),(539,232),(707,459),(775,301),(749,191),(92,109),(405,592),(232,607),(89,148),(960,869),(710,127),(720,207),(331,889),(312,687),(277,782),(503,142),(679,33),(498,428),(102,48),(643,990),(79,529),(458,732),(628,218),(204,587),(708,345),(789,711),(871,821),(612,866),(340,344),(29,842),(514,474),(376,430),(662,447),(1004,771),(92,137),(993,957),(933,88),(131,56),(874,334),(721,194),(132,836),(292,80),(260,675),(232,401),(305,362),(294,982),(428,113),(611,548),(964,609),(313,510),(989,524),(327,287),(291,59),(134,595),(153,424),(366,690),(444,300),(858,1001),(381,576),(668,853),(966,391),(713,326),(510,362),(428,127),(811,153),(957,690),(132,382),(569,929),(433,417),(556,35),(830,523),(949,74),(302,552),(549,26),(101,870),(282,6),(849,404),(725,358),(184,353),(478,679),(699,194),(427,332),(289,32),(283,384),(915,123),(594,220),(310,809),(609,475),(353,48),(450,113),(862,877),(190,469),(723,549),(117,287),(944,273),(223,604),(539,687),(178,660),(441,184),(102,618),(91,1015),(418,555),(896,276),(505,715),(991,962),(986,953),(928,539),(635,972),(944,391),(397,10),(134,375),(769,12),(968,873),(280,982),(753,573),(644,306),(840,412),(100,318),(885,906),(888,236),(240,123),(790,443),(708,109),(125,433),(711,420),(644,750),(540,886),(837,463),(133,999),(391,47),(629,572),(256,975),(89,443),(523,583),(1016,945),(125,601),(855,804),(196,152),(700,195),(9,806),(877,812),(933,375),(909,973),(227,847),(926,384),(751,438),(796,334),(584,309),(203,7),(956,365),(595,664),(127,74),(329,985),(930,635),(588,493),(919,168),(773,328),(282,352),(552,793),(473,460),(497,1001),(658,335),(17,582),(844,34),(740,972),(72,877),(897,426),(151,379),(508,594),(842,69),(326,974),(731,370),(397,511),(165,390),(195,623),(195,158),(187,994),(158,359),(151,432),(124,951),(497,328),(472,322),(476,570),(567,409),(196,963),(153,945),(225,452),(311,668),(959,794),(772,442),(943,391),(713,834),(813,970),(37,700),(247,614),(56,723),(554,612),(987,947),(63,223),(703,295),(707,61),(730,930),(791,565),(470,540),(244,339),(696,636),(365,403),(817,281),(42,811),(367,68),(636,259),(870,211),(185,440),(583,295),(959,827),(372,738),(462,797),(995,660),(994,86),(745,303),(896,289),(1007,983),(608,76),(967,623),(568,460),(703,446),(910,192),(752,657),(524,662),(611,933),(495,143),(88,922),(310,529),(561,1007),(788,320),(224,539),(400,758),(251,937),(438,842),(243,8),(427,291),(690,557),(19,45),(998,100),(455,755),(981,1019),(51,140),(742,546),(274,726),(914,911),(730,72),(169,222),(631,797),(857,752))' as PATH
                                    ) as PATH
                                ) AS INTEGER
                            ) >> CAST(
                                character_length(
                                    CAST(
                                        CAST(
                                            'XM7vn1^dFs#oH8T0X4E^T[eCRb?$-_AjWV_o~h-3dAyAaF+g?mzA(@C{zo24kmEPSb1&7(z7C3u.98LS3pw6DQ1L@){WyZ244A]H3]+8Of1\\?8z+FB#D31O4700Xa3{9+3xqX3prPq4)-K.^}xS}IVB*55DzS^EPTyuT+2ad^696xARGGEQmCCYD83Wn8cy6w]62*wER~3DbMTP)+9$47B.^U~?4yq_FT.YNcFc~6i!yvA#I8TAV{/k60646a*A0' as TEXT
                                        ) as TEXT
                                    )
                                ) AS INTEGER
                            ) AS INTEGER
                        ) as INTEGER
                    )
                ) OVER (
                    PARTITION BY ref_0.s_quantity
                    ORDER BY ref_0.xmin
                ) as INTEGER
            )
        ) as c4,
        ref_0.s_dist_09 as c5,
        (
            SELECT xc_node_id
            FROM  bmsql_config
            LIMIT 1 OFFSET 1
        ) as c6,
        ref_0.s_dist_08 as c7,
        49 as c8,
        ref_3.no_d_id as c9,
        ref_3.xmin as c10,
        var_samp(
            CAST(
                CAST(
                    CAST(
                        '((158,167),(913,169),(226,935),(741,596),(65,384),(221,794),(642,75),(512,474),(706,583),(903,982),(3,923),(979,23),(759,688),(43,761),(52,289),(245,172),(683,914),(654,767),(715,1000),(175,263),(188,291),(210,214),(775,872),(955,992),(357,289),(2,31),(498,296),(873,361),(564,60),(734,15),(263,369),(667,785),(90,133),(575,897),(53,357),(637,712),(852,693),(297,813),(233,697),(167,775),(163,240),(836,927),(363,847),(155,94),(534,27),(485,367),(697,792),(353,849),(653,36),(893,336),(826,517),(303,301),(629,346),(228,273),(472,1007),(681,855),(22,439),(654,267),(940,226),(225,718),(874,620),(823,522),(765,148),(52,693),(809,603),(853,892),(365,910),(265,55),(788,884),(390,588),(856,320),(272,875),(954,809),(880,597),(611,157),(799,313),(832,749),(986,964),(661,507),(655,670),(792,150),(224,556),(711,196),(944,417),(170,253),(416,868),(193,1009),(941,642),(67,60),(752,728),(617,536),(283,225),(37,306),(438,926),(102,999),(543,464),(237,402),(195,911),(689,877),(28,397),(195,642),(883,715),(821,730),(2,795),(292,73),(534,761),(997,830),(610,71),(789,322),(173,249),(388,614),(513,79),(411,341),(371,985),(568,733),(994,700),(183,565),(332,280),(172,717),(312,5),(639,844),(298,26),(967,172),(29,419),(776,755),(654,120),(886,656),(8,461),(66,638),(147,581),(19,484),(927,749),(547,574),(630,83),(541,1014),(681,507),(162,535),(417,943),(470,814),(525,312),(629,299),(737,413),(104,582),(317,354),(957,228),(931,286),(344,824),(837,719),(862,925),(944,309),(782,92),(498,302),(85,583),(161,293),(204,290),(848,710),(753,690),(997,844),(719,149),(75,760),(439,950),(852,142),(897,581),(612,1024),(676,766),(785,443),(602,616),(329,216),(22,696),(89,667),(907,669),(1024,592),(228,805),(92,229),(989,284),(397,80),(887,868),(260,483),(879,244),(450,633),(747,69),(553,405),(158,653),(822,887),(662,319),(839,500),(169,969),(172,705),(1005,156),(998,252),(1025,1021),(218,820),(894,459),(85,375),(956,375),(148,979),(442,729),(65,541),(383,973),(827,685),(834,18),(238,237),(1003,221),(467,17),(422,153),(879,741),(654,249),(828,144),(838,588),(994,440),(501,84),(447,805),(125,606),(994,645),(1022,603),(64,584),(277,315),(832,676),(931,781),(24,163),(285,10),(926,711),(346,166),(1014,778),(645,191),(234,782),(547,918),(218,1001),(387,877),(290,795),(457,943),(877,498),(149,213),(941,780),(222,631),(568,402),(744,532),(711,641),(723,334),(431,359),(444,443),(442,804),(677,620),(457,452),(209,365),(368,51),(918,544),(768,327),(538,535),(351,686),(737,136),(371,655),(293,811),(1003,1011),(364,38),(116,739))' as PATH
                    ) as PATH
                ) as INTEGER
            )
        ) OVER (
            PARTITION BY ref_1.o_id
            ORDER BY ref_1.o_w_id
        ) as c11,
        ref_2.d_zip as c12,
        (
            SELECT xmin
            FROM  t_explain_0073_3
            LIMIT 1 OFFSET 3
        ) as c13
    from  t_explain_0073_3 as ref_3
    WHERE EXISTS (
            SELECT DISTINCT ref_1.o_entry_d as c0,
                ref_0.s_dist_04 as c1,
                ref_3.ctid as c2,
                ref_2.d_w_id as c3,
                ref_0.xmin as c4,
                ref_1.cmax as c5,
                pg_stat_get_function_total_time(
                    CAST(
                        @ CAST(
                            CAST(
                                octet_length(
                                    CAST(
                                        CAST(
                                            '(8~fM\\m4)@B6EB%cO#Chg8L#Jh7u(Xny7HE{]XwN(U8E^5[AA3RkjsQjwU++]D&?!VZ3_1JORkfCnCS/1X+iL&e1+Z70VaC+b9&hrL+Kr2#/{H&]74]%9Dvf[X9I$T*+4+!@dx8BWDS@ExG1I}3VHTM\\$yr4xB3vE)D8xhJ52D?&n\\.IXu6D.ACNeO$!*3?[nf#BAROaT#2rdIak1ZR(gXy#4D/2XX8*rJpe11C!iu5)~3pw&8L1V2&BwxM+6F7F' as TEXT
                                        ) as TEXT
                                    )
                                ) AS INTEGER
                            ) + CAST(73 AS INTEGER) as INTEGER
                        ) as INTEGER
                    )
                ) as c6
            from  t_explain_0073_1 as ref_4
            WHERE true
            LIMIT 37
        )
)
LIMIT 101;

--step3:清理环境;expect:成功
drop table if exists t_explain_0073_1, t_explain_0073_2, t_explain_0073_3, t_explain_0073_4, t_explain_0073_5, t_explain_0073_6 cascade;
